const express = require('express');
const path = require('path');
const app = express();
var compression = require ( 'compression')
app.use(compression());
app.use('/', express.static('public'))

// 端口号
const port = 12000;
// 注册全局解析中间件
app.use(express.json());
app.use(express.urlencoded({ extended: false }));

// 调用 app.listen() 启动服务器
app.listen(port, () => console.log(`web listen on port 11000!`));
